package com.hnkywl.sts.entity.base;

import com.hnkywl.sts.entity.BaseEntity;
import com.hnkywl.sts.entity.organ.Gsjg;
import org.hibernate.annotations.Where;

import javax.persistence.*;
import java.util.Date;
import java.util.List;

/**
 * 说明：系统公告
 * 包:        com.hnkywl.sts.entity.base
 * 类描述:    数据字典值
 * 修改备注: [说明本次修改内容]
 * 版本:        [v1.0]
 */
@Entity
@Table(name="T_BIZ_XTGG")
@Where(clause = "deleted!='1'")
public class Xtgg extends BaseEntity{
    @Id
    @SequenceGenerator(name = "seqXtgg", allocationSize = 1, sequenceName = "SEQ_BIZ_XTGG")
    @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "seqXtgg")
    private Long id;

    /**
     * 系统公告标题
     */
    private String ggbt;

    /**
     * 系统公告内容
     */
    private String ggnr;

    /**
     * 置顶
     */
    private Boolean zd;

    /**
     * 公告状态，0：未发布，1：已发布 ,2:已撤销发布
     */
    private String ggzt;

    /**
     * 发布时间
     */
    private Date fbdate;
    /**
     * 公司
     */
    @ManyToMany
    @JoinTable(name="T_BIZ_XTGG_GSJG", joinColumns={@JoinColumn(name="XTGG_ID")},inverseJoinColumns={@JoinColumn(name="GSJG_ID")})
    @Where(clause = "deleted!='1'")
    private List<Gsjg> gsjgList;


    public List<Gsjg> getGsjgList() {
        return gsjgList;
    }

    public void setGsjgList(List<Gsjg> gsjgList) {
        this.gsjgList = gsjgList;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getGgbt() {
        return ggbt;
    }

    public void setGgbt(String ggbt) {
        this.ggbt = ggbt;
    }

    public String getGgnr() {
        return ggnr;
    }

    public void setGgnr(String ggnr) {
        this.ggnr = ggnr;
    }

    public Boolean getZd() {
        return zd;
    }

    public void setZd(Boolean zd) {
        this.zd = zd;
    }

    public String getGgzt() {
        return ggzt;
    }

    public void setGgzt(String ggzt) {
        this.ggzt = ggzt;
    }

    public Date getFbdate() {
        return fbdate;
    }

    public void setFbdate(Date fbdate) {
        this.fbdate = fbdate;
    }
}
